home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / SourceCode / AlexNeXTSTEPSource / Source / Chapter3_OOD / ShapeArea / Rectangle.m < prev    next >
Text File  |  1995-06-12  |  229b  |  24 lines

  1. #import "Rectangle.h"
  2.  
  3. @implementation Rectangle
  4.  
  5. -initHeight:(float)h width:(float)w
  6. {
  7.     [super init];
  8.     height = h;
  9.     width = w;
  10.     return self;
  11. }
  12.  
  13. -(float)calcArea
  14. {
  15.     return height * width;
  16. }
  17.  
  18. -free
  19. {
  20.     return [super free];
  21. }
  22.  
  23. @end
  24.